package cn.itcast.bos.utils;

public class TestString {

	public static void main(String[] args) {
		String string = "{'code':200,'msg':'3','obj':'536291'}";
		String[] split = string.split(",");
		System.out.println(split[1].length());
        /**
         * 截成3部分
         * 1.{"code":200
         * 2."msg":"3"
         * 3."obj":"536291"}
         */
        String code = split[0].substring(8);
        String msg = split[1].substring(7, split[1].length()-1);
        String obj = split[2].substring(7, split[2].length()-2);
        System.out.println("code:"+code);
        System.out.println("msg:"+msg);
        System.out.println("obj:"+obj);
	}
}
